<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
    <style>
        #box3{
            background-color: yellow;
            height: 50px;
        }
        #box4{
            background-color: red;
        }
        img{
            display: block;
            /* 一整行 */
            margin: 0 auto;
            /* 上下为0  左右自适应 */
        }
        .item{
            float: left;
            width: 300px;
            height: 150px;
            background-color: aquamarine;
        }

    </style>

</head>
<body>
<div id="box3">
    <div class="item">1</div>
    <div class="item">2</div>
    <div class="item">3</div>
</div>
    <div id="box4">
        <img src="https://www.baidu.com/img/PCtm_d9c8750bed0b3c7d089fa7d55720d6cf.png" />
   
        <img src="https://www.baidu.com/img/PCtm_d9c8750bed0b3c7d089fa7d55720d6cf.png" />
    </div>
    
</body>
</html>